\contentsline {section}{\numberline {1}Introduction}{4}{section.1}
\contentsline {subsection}{\numberline {1.1}Getting help}{4}{subsection.1.1}
\contentsline {subsection}{\numberline {1.2}Helping us}{4}{subsection.1.2}
\contentsline {section}{\numberline {2}Suggested workflow}{4}{section.2}
\contentsline {section}{\numberline {3}Importing data}{5}{section.3}
\contentsline {subsection}{\numberline {3.1}Frequency spectrum file format}{5}{subsection.3.1}
\contentsline {subsection}{\numberline {3.2}SNP data format}{6}{subsection.3.2}
\contentsline {subsection}{\numberline {3.3}SNP data methods}{6}{subsection.3.3}
\contentsline {section}{\numberline {4}Manipulating spectra}{7}{section.4}
\contentsline {subsection}{\numberline {4.1}Summary statistics}{8}{subsection.4.1}
\contentsline {subsubsection}{\numberline {4.1.1}Single-population statistics}{8}{subsubsection.4.1.1}
\contentsline {subsubsection}{\numberline {4.1.2}Multi-population statistics}{8}{subsubsection.4.1.2}
\contentsline {subsection}{\numberline {4.2}Folding}{8}{subsection.4.2}
\contentsline {subsection}{\numberline {4.3}Masking}{9}{subsection.4.3}
\contentsline {subsection}{\numberline {4.4}Marginalizing}{9}{subsection.4.4}
\contentsline {subsection}{\numberline {4.5}Projection}{9}{subsection.4.5}
\contentsline {subsection}{\numberline {4.6}Sampling}{10}{subsection.4.6}
\contentsline {subsection}{\numberline {4.7}Scrambling}{10}{subsection.4.7}
\contentsline {section}{\numberline {5}Specifying a model}{10}{section.5}
\contentsline {subsection}{\numberline {5.1}Implementation}{10}{subsection.5.1}
\contentsline {subsection}{\numberline {5.2}Units}{12}{subsection.5.2}
\contentsline {subsection}{\numberline {5.3}Fixed $\theta $}{12}{subsection.5.3}
\contentsline {subsection}{\numberline {5.4}Ancient sequences}{12}{subsection.5.4}
\contentsline {section}{\numberline {6}Simulation and fitting}{19}{section.6}
\contentsline {subsection}{\numberline {6.1}Grid sizes and extrapolation}{19}{subsection.6.1}
\contentsline {subsubsection}{\numberline {6.1.1}Grid choice}{19}{subsubsection.6.1.1}
\contentsline {subsection}{\numberline {6.2}Likelihoods}{21}{subsection.6.2}
\contentsline {subsection}{\numberline {6.3}Fitting}{21}{subsection.6.3}
\contentsline {subsubsection}{\numberline {6.3.1}Parameter bounds}{21}{subsubsection.6.3.1}
\contentsline {subsection}{\numberline {6.4}Fixing parameters}{22}{subsection.6.4}
\contentsline {subsection}{\numberline {6.5}Which optimizer should I use?}{22}{subsection.6.5}
\contentsline {section}{\numberline {7}Plotting}{22}{section.7}
\contentsline {subsection}{\numberline {7.1}Essential matplotlib commands}{23}{subsection.7.1}
\contentsline {subsection}{\numberline {7.2}1D comparison}{23}{subsection.7.2}
\contentsline {subsection}{\numberline {7.3}2D spectra}{24}{subsection.7.3}
\contentsline {subsection}{\numberline {7.4}2D comparison}{24}{subsection.7.4}
\contentsline {subsection}{\numberline {7.5}3D spectra}{24}{subsection.7.5}
\contentsline {subsection}{\numberline {7.6}3D comparison}{24}{subsection.7.6}
\contentsline {subsection}{\numberline {7.7}Residuals}{24}{subsection.7.7}
\contentsline {section}{\numberline {8}Bootstrapping}{25}{section.8}
\contentsline {subsection}{\numberline {8.1}Interacting with \emph {ms}\xspace }{27}{subsection.8.1}
\contentsline {section}{\numberline {9}Uncertainty analysis}{27}{section.9}
\contentsline {section}{\numberline {10}Likelihood ratio test}{27}{section.10}
\contentsline {section}{\numberline {11}Installation}{28}{section.11}
\contentsline {subsection}{\numberline {11.1}Dependencies}{28}{subsection.11.1}
\contentsline {subsection}{\numberline {11.2}Binary packages}{28}{subsection.11.2}
\contentsline {subsection}{\numberline {11.3}Installing from source}{29}{subsection.11.3}
\contentsline {subsubsection}{\numberline {11.3.1}Windows}{29}{subsubsection.11.3.1}
\contentsline {section}{\numberline {12}Frequently asked questions}{29}{section.12}
